package com.msb.user_consumer;

import com.msb.user_api.Person;
import org.springframework.stereotype.Component;

import java.util.Map;

@Component
public class UserProviderBack implements UserApi {
    /**
     * 这里 getMapping 是给Feign看的 get请求 user-provider/getMap?id={1}
     *
     * @param id
     * @return
     * @RequestParam("id") 也是给Feign看的
     * <p>
     * HttpClient Http协议
     */
    @Override
    public Map<Integer, String> getMap(Integer id) {
        return null;
    }

    /**
     * @param id
     * @param name
     * @return
     * @RequestParam("id") @RequestParam("name") 不可以删除
     */
    @Override
    public Map<Integer, String> getMap2(Integer id, String name) {
        return null;
    }

    @Override
    public Map<Integer, String> getMap3(Map<String, Object> map) {
        return null;
    }

    @Override
    public Map<Integer, String> postMap(Map<String, Object> map) {
        return null;
    }

    @Override
    public String alive() {
        System.out.println("================降级了");
        return "降级了";
    }

    @Override
    public Person postPerson(Person person) {
        return null;
    }
}
